package com.fc.v2.model.auto;

import java.util.ArrayList;
import java.util.Date;
import java.util.List;
import cn.hutool.core.util.StrUtil;

/**
 * 单位表 SysPositionExample
 * @author Archie_自动生成
 * @date 2021-12-04 17:57:59
 */
public class SysPositionExample {

    protected String orderByClause;

    protected boolean distinct;

    protected List<Criteria> oredCriteria;

    public SysPositionExample() {
        oredCriteria = new ArrayList<Criteria>();
    }

    public void setOrderByClause(String orderByClause) {
        this.orderByClause = orderByClause;
    }

    public String getOrderByClause() {
        return orderByClause;
    }

    public void setDistinct(boolean distinct) {
        this.distinct = distinct;
    }

    public boolean isDistinct() {
        return distinct;
    }

    public List<Criteria> getOredCriteria() {
        return oredCriteria;
    }

    public void or(Criteria criteria) {
        oredCriteria.add(criteria);
    }

    public Criteria or() {
        Criteria criteria = createCriteriaInternal();
        oredCriteria.add(criteria);
        return criteria;
    }

    public Criteria createCriteria() {
        Criteria criteria = createCriteriaInternal();
        if (oredCriteria.size() == 0) {
            oredCriteria.add(criteria);
        }
        return criteria;
    }

    protected Criteria createCriteriaInternal() {
        Criteria criteria = new Criteria();
        return criteria;
    }

    public void clear() {
        oredCriteria.clear();
        orderByClause = null;
        distinct = false;
    }

    protected abstract static class GeneratedCriteria {
        protected List<Criterion> criteria;

        protected GeneratedCriteria() {
            super();
            criteria = new ArrayList<Criterion>();
        }

        public boolean isValid() {
            return criteria.size() > 0;
        }

        public List<Criterion> getAllCriteria() {
            return criteria;
        }

        public List<Criterion> getCriteria() {
            return criteria;
        }

        protected void addCriterion(String condition) {
            if (condition == null) {
                throw new RuntimeException("Value for condition cannot be null");
            }
            criteria.add(new Criterion(condition));
        }

        protected void addCriterion(String condition, Object value, String property) {
            if (value == null) {
                throw new RuntimeException("Value for " + property + " cannot be null");
            }
            criteria.add(new Criterion(condition, value));
        }

        protected void addCriterion(String condition, Object value1, Object value2, String property) {
            if (value1 == null || value2 == null) {
                throw new RuntimeException("Between values for " + property + " cannot be null");
            }
            criteria.add(new Criterion(condition, value1, value2));
        }
        
				
        public Criteria andIdIsNull() {
            addCriterion("id is null");
            return (Criteria) this;
        }

        public Criteria andIdIsNotNull() {
            addCriterion("id is not null");
            return (Criteria) this;
        }

        public Criteria andIdEqualTo(String value) {
            addCriterion("id =", value, "id");
            return (Criteria) this;
        }

        public Criteria andIdNotEqualTo(String value) {
            addCriterion("id <>", value, "id");
            return (Criteria) this;
        }

        public Criteria andIdGreaterThan(String value) {
            addCriterion("id >", value, "id");
            return (Criteria) this;
        }

        public Criteria andIdGreaterThanOrEqualTo(String value) {
            addCriterion("id >=", value, "id");
            return (Criteria) this;
        }

        public Criteria andIdLessThan(String value) {
            addCriterion("id <", value, "id");
            return (Criteria) this;
        }

        public Criteria andIdLessThanOrEqualTo(String value) {
            addCriterion("id <=", value, "id");
            return (Criteria) this;
        }

        public Criteria andIdLike(String value) {
            addCriterion("id like", value, "id");
            return (Criteria) this;
        }

        public Criteria andIdNotLike(String value) {
            addCriterion("id not like", value, "id");
            return (Criteria) this;
        }

        public Criteria andIdIn(List<String> values) {
            addCriterion("id in", values, "id");
            return (Criteria) this;
        }

        public Criteria andIdNotIn(List<String> values) {
            addCriterion("id not in", values, "id");
            return (Criteria) this;
        }

        public Criteria andIdBetween(String value1, String value2) {
            addCriterion("id between", value1, value2, "id");
            return (Criteria) this;
        }

        public Criteria andIdNotBetween(String value1, String value2) {
            addCriterion("id not between", value1, value2, "id");
            return (Criteria) this;
        }
        
				
        public Criteria andDeptNameIsNull() {
            addCriterion("dept_name is null");
            return (Criteria) this;
        }

        public Criteria andDeptNameIsNotNull() {
            addCriterion("dept_name is not null");
            return (Criteria) this;
        }

        public Criteria andDeptNameEqualTo(String value) {
            addCriterion("dept_name =", value, "deptName");
            return (Criteria) this;
        }

        public Criteria andDeptNameNotEqualTo(String value) {
            addCriterion("dept_name <>", value, "deptName");
            return (Criteria) this;
        }

        public Criteria andDeptNameGreaterThan(String value) {
            addCriterion("dept_name >", value, "deptName");
            return (Criteria) this;
        }

        public Criteria andDeptNameGreaterThanOrEqualTo(String value) {
            addCriterion("dept_name >=", value, "deptName");
            return (Criteria) this;
        }

        public Criteria andDeptNameLessThan(String value) {
            addCriterion("dept_name <", value, "deptName");
            return (Criteria) this;
        }

        public Criteria andDeptNameLessThanOrEqualTo(String value) {
            addCriterion("dept_name <=", value, "deptName");
            return (Criteria) this;
        }

        public Criteria andDeptNameLike(String value) {
            addCriterion("dept_name like", value, "deptName");
            return (Criteria) this;
        }

        public Criteria andDeptNameNotLike(String value) {
            addCriterion("dept_name not like", value, "deptName");
            return (Criteria) this;
        }

        public Criteria andDeptNameIn(List<String> values) {
            addCriterion("dept_name in", values, "deptName");
            return (Criteria) this;
        }

        public Criteria andDeptNameNotIn(List<String> values) {
            addCriterion("dept_name not in", values, "deptName");
            return (Criteria) this;
        }

        public Criteria andDeptNameBetween(String value1, String value2) {
            addCriterion("dept_name between", value1, value2, "deptName");
            return (Criteria) this;
        }

        public Criteria andDeptNameNotBetween(String value1, String value2) {
            addCriterion("dept_name not between", value1, value2, "deptName");
            return (Criteria) this;
        }
        
				
        public Criteria andOrderNumIsNull() {
            addCriterion("order_num is null");
            return (Criteria) this;
        }

        public Criteria andOrderNumIsNotNull() {
            addCriterion("order_num is not null");
            return (Criteria) this;
        }

        public Criteria andOrderNumEqualTo(Integer value) {
            addCriterion("order_num =", value, "orderNum");
            return (Criteria) this;
        }

        public Criteria andOrderNumNotEqualTo(Integer value) {
            addCriterion("order_num <>", value, "orderNum");
            return (Criteria) this;
        }

        public Criteria andOrderNumGreaterThan(Integer value) {
            addCriterion("order_num >", value, "orderNum");
            return (Criteria) this;
        }

        public Criteria andOrderNumGreaterThanOrEqualTo(Integer value) {
            addCriterion("order_num >=", value, "orderNum");
            return (Criteria) this;
        }

        public Criteria andOrderNumLessThan(Integer value) {
            addCriterion("order_num <", value, "orderNum");
            return (Criteria) this;
        }

        public Criteria andOrderNumLessThanOrEqualTo(Integer value) {
            addCriterion("order_num <=", value, "orderNum");
            return (Criteria) this;
        }

        public Criteria andOrderNumLike(Integer value) {
            addCriterion("order_num like", value, "orderNum");
            return (Criteria) this;
        }

        public Criteria andOrderNumNotLike(Integer value) {
            addCriterion("order_num not like", value, "orderNum");
            return (Criteria) this;
        }

        public Criteria andOrderNumIn(List<Integer> values) {
            addCriterion("order_num in", values, "orderNum");
            return (Criteria) this;
        }

        public Criteria andOrderNumNotIn(List<Integer> values) {
            addCriterion("order_num not in", values, "orderNum");
            return (Criteria) this;
        }

        public Criteria andOrderNumBetween(Integer value1, Integer value2) {
            addCriterion("order_num between", value1, value2, "orderNum");
            return (Criteria) this;
        }

        public Criteria andOrderNumNotBetween(Integer value1, Integer value2) {
            addCriterion("order_num not between", value1, value2, "orderNum");
            return (Criteria) this;
        }
        
				
        public Criteria andStatusIsNull() {
            addCriterion("status is null");
            return (Criteria) this;
        }

        public Criteria andStatusIsNotNull() {
            addCriterion("status is not null");
            return (Criteria) this;
        }

        public Criteria andStatusEqualTo(Integer value) {
            addCriterion("status =", value, "status");
            return (Criteria) this;
        }

        public Criteria andStatusNotEqualTo(Integer value) {
            addCriterion("status <>", value, "status");
            return (Criteria) this;
        }

        public Criteria andStatusGreaterThan(Integer value) {
            addCriterion("status >", value, "status");
            return (Criteria) this;
        }

        public Criteria andStatusGreaterThanOrEqualTo(Integer value) {
            addCriterion("status >=", value, "status");
            return (Criteria) this;
        }

        public Criteria andStatusLessThan(Integer value) {
            addCriterion("status <", value, "status");
            return (Criteria) this;
        }

        public Criteria andStatusLessThanOrEqualTo(Integer value) {
            addCriterion("status <=", value, "status");
            return (Criteria) this;
        }

        public Criteria andStatusLike(Integer value) {
            addCriterion("status like", value, "status");
            return (Criteria) this;
        }

        public Criteria andStatusNotLike(Integer value) {
            addCriterion("status not like", value, "status");
            return (Criteria) this;
        }

        public Criteria andStatusIn(List<Integer> values) {
            addCriterion("status in", values, "status");
            return (Criteria) this;
        }

        public Criteria andStatusNotIn(List<Integer> values) {
            addCriterion("status not in", values, "status");
            return (Criteria) this;
        }

        public Criteria andStatusBetween(Integer value1, Integer value2) {
            addCriterion("status between", value1, value2, "status");
            return (Criteria) this;
        }

        public Criteria andStatusNotBetween(Integer value1, Integer value2) {
            addCriterion("status not between", value1, value2, "status");
            return (Criteria) this;
        }
        
				
        public Criteria andBankAccountIsNull() {
            addCriterion("bank_account is null");
            return (Criteria) this;
        }

        public Criteria andBankAccountIsNotNull() {
            addCriterion("bank_account is not null");
            return (Criteria) this;
        }

        public Criteria andBankAccountEqualTo(String value) {
            addCriterion("bank_account =", value, "bankAccount");
            return (Criteria) this;
        }

        public Criteria andBankAccountNotEqualTo(String value) {
            addCriterion("bank_account <>", value, "bankAccount");
            return (Criteria) this;
        }

        public Criteria andBankAccountGreaterThan(String value) {
            addCriterion("bank_account >", value, "bankAccount");
            return (Criteria) this;
        }

        public Criteria andBankAccountGreaterThanOrEqualTo(String value) {
            addCriterion("bank_account >=", value, "bankAccount");
            return (Criteria) this;
        }

        public Criteria andBankAccountLessThan(String value) {
            addCriterion("bank_account <", value, "bankAccount");
            return (Criteria) this;
        }

        public Criteria andBankAccountLessThanOrEqualTo(String value) {
            addCriterion("bank_account <=", value, "bankAccount");
            return (Criteria) this;
        }

        public Criteria andBankAccountLike(String value) {
            addCriterion("bank_account like", value, "bankAccount");
            return (Criteria) this;
        }

        public Criteria andBankAccountNotLike(String value) {
            addCriterion("bank_account not like", value, "bankAccount");
            return (Criteria) this;
        }

        public Criteria andBankAccountIn(List<String> values) {
            addCriterion("bank_account in", values, "bankAccount");
            return (Criteria) this;
        }

        public Criteria andBankAccountNotIn(List<String> values) {
            addCriterion("bank_account not in", values, "bankAccount");
            return (Criteria) this;
        }

        public Criteria andBankAccountBetween(String value1, String value2) {
            addCriterion("bank_account between", value1, value2, "bankAccount");
            return (Criteria) this;
        }

        public Criteria andBankAccountNotBetween(String value1, String value2) {
            addCriterion("bank_account not between", value1, value2, "bankAccount");
            return (Criteria) this;
        }
        
				
        public Criteria andDeptAddressIsNull() {
            addCriterion("dept_address is null");
            return (Criteria) this;
        }

        public Criteria andDeptAddressIsNotNull() {
            addCriterion("dept_address is not null");
            return (Criteria) this;
        }

        public Criteria andDeptAddressEqualTo(String value) {
            addCriterion("dept_address =", value, "deptAddress");
            return (Criteria) this;
        }

        public Criteria andDeptAddressNotEqualTo(String value) {
            addCriterion("dept_address <>", value, "deptAddress");
            return (Criteria) this;
        }

        public Criteria andDeptAddressGreaterThan(String value) {
            addCriterion("dept_address >", value, "deptAddress");
            return (Criteria) this;
        }

        public Criteria andDeptAddressGreaterThanOrEqualTo(String value) {
            addCriterion("dept_address >=", value, "deptAddress");
            return (Criteria) this;
        }

        public Criteria andDeptAddressLessThan(String value) {
            addCriterion("dept_address <", value, "deptAddress");
            return (Criteria) this;
        }

        public Criteria andDeptAddressLessThanOrEqualTo(String value) {
            addCriterion("dept_address <=", value, "deptAddress");
            return (Criteria) this;
        }

        public Criteria andDeptAddressLike(String value) {
            addCriterion("dept_address like", value, "deptAddress");
            return (Criteria) this;
        }

        public Criteria andDeptAddressNotLike(String value) {
            addCriterion("dept_address not like", value, "deptAddress");
            return (Criteria) this;
        }

        public Criteria andDeptAddressIn(List<String> values) {
            addCriterion("dept_address in", values, "deptAddress");
            return (Criteria) this;
        }

        public Criteria andDeptAddressNotIn(List<String> values) {
            addCriterion("dept_address not in", values, "deptAddress");
            return (Criteria) this;
        }

        public Criteria andDeptAddressBetween(String value1, String value2) {
            addCriterion("dept_address between", value1, value2, "deptAddress");
            return (Criteria) this;
        }

        public Criteria andDeptAddressNotBetween(String value1, String value2) {
            addCriterion("dept_address not between", value1, value2, "deptAddress");
            return (Criteria) this;
        }
        
				
        public Criteria andDeptZipIsNull() {
            addCriterion("dept_zip is null");
            return (Criteria) this;
        }

        public Criteria andDeptZipIsNotNull() {
            addCriterion("dept_zip is not null");
            return (Criteria) this;
        }

        public Criteria andDeptZipEqualTo(String value) {
            addCriterion("dept_zip =", value, "deptZip");
            return (Criteria) this;
        }

        public Criteria andDeptZipNotEqualTo(String value) {
            addCriterion("dept_zip <>", value, "deptZip");
            return (Criteria) this;
        }

        public Criteria andDeptZipGreaterThan(String value) {
            addCriterion("dept_zip >", value, "deptZip");
            return (Criteria) this;
        }

        public Criteria andDeptZipGreaterThanOrEqualTo(String value) {
            addCriterion("dept_zip >=", value, "deptZip");
            return (Criteria) this;
        }

        public Criteria andDeptZipLessThan(String value) {
            addCriterion("dept_zip <", value, "deptZip");
            return (Criteria) this;
        }

        public Criteria andDeptZipLessThanOrEqualTo(String value) {
            addCriterion("dept_zip <=", value, "deptZip");
            return (Criteria) this;
        }

        public Criteria andDeptZipLike(String value) {
            addCriterion("dept_zip like", value, "deptZip");
            return (Criteria) this;
        }

        public Criteria andDeptZipNotLike(String value) {
            addCriterion("dept_zip not like", value, "deptZip");
            return (Criteria) this;
        }

        public Criteria andDeptZipIn(List<String> values) {
            addCriterion("dept_zip in", values, "deptZip");
            return (Criteria) this;
        }

        public Criteria andDeptZipNotIn(List<String> values) {
            addCriterion("dept_zip not in", values, "deptZip");
            return (Criteria) this;
        }

        public Criteria andDeptZipBetween(String value1, String value2) {
            addCriterion("dept_zip between", value1, value2, "deptZip");
            return (Criteria) this;
        }

        public Criteria andDeptZipNotBetween(String value1, String value2) {
            addCriterion("dept_zip not between", value1, value2, "deptZip");
            return (Criteria) this;
        }
        
				
        public Criteria andApplyNumberIsNull() {
            addCriterion("apply_number is null");
            return (Criteria) this;
        }

        public Criteria andApplyNumberIsNotNull() {
            addCriterion("apply_number is not null");
            return (Criteria) this;
        }

        public Criteria andApplyNumberEqualTo(String value) {
            addCriterion("apply_number =", value, "applyNumber");
            return (Criteria) this;
        }

        public Criteria andApplyNumberNotEqualTo(String value) {
            addCriterion("apply_number <>", value, "applyNumber");
            return (Criteria) this;
        }

        public Criteria andApplyNumberGreaterThan(String value) {
            addCriterion("apply_number >", value, "applyNumber");
            return (Criteria) this;
        }

        public Criteria andApplyNumberGreaterThanOrEqualTo(String value) {
            addCriterion("apply_number >=", value, "applyNumber");
            return (Criteria) this;
        }

        public Criteria andApplyNumberLessThan(String value) {
            addCriterion("apply_number <", value, "applyNumber");
            return (Criteria) this;
        }

        public Criteria andApplyNumberLessThanOrEqualTo(String value) {
            addCriterion("apply_number <=", value, "applyNumber");
            return (Criteria) this;
        }

        public Criteria andApplyNumberLike(String value) {
            addCriterion("apply_number like", value, "applyNumber");
            return (Criteria) this;
        }

        public Criteria andApplyNumberNotLike(String value) {
            addCriterion("apply_number not like", value, "applyNumber");
            return (Criteria) this;
        }

        public Criteria andApplyNumberIn(List<String> values) {
            addCriterion("apply_number in", values, "applyNumber");
            return (Criteria) this;
        }

        public Criteria andApplyNumberNotIn(List<String> values) {
            addCriterion("apply_number not in", values, "applyNumber");
            return (Criteria) this;
        }

        public Criteria andApplyNumberBetween(String value1, String value2) {
            addCriterion("apply_number between", value1, value2, "applyNumber");
            return (Criteria) this;
        }

        public Criteria andApplyNumberNotBetween(String value1, String value2) {
            addCriterion("apply_number not between", value1, value2, "applyNumber");
            return (Criteria) this;
        }
        
				
        public Criteria andFinishNumberIsNull() {
            addCriterion("finish_number is null");
            return (Criteria) this;
        }

        public Criteria andFinishNumberIsNotNull() {
            addCriterion("finish_number is not null");
            return (Criteria) this;
        }

        public Criteria andFinishNumberEqualTo(String value) {
            addCriterion("finish_number =", value, "finishNumber");
            return (Criteria) this;
        }

        public Criteria andFinishNumberNotEqualTo(String value) {
            addCriterion("finish_number <>", value, "finishNumber");
            return (Criteria) this;
        }

        public Criteria andFinishNumberGreaterThan(String value) {
            addCriterion("finish_number >", value, "finishNumber");
            return (Criteria) this;
        }

        public Criteria andFinishNumberGreaterThanOrEqualTo(String value) {
            addCriterion("finish_number >=", value, "finishNumber");
            return (Criteria) this;
        }

        public Criteria andFinishNumberLessThan(String value) {
            addCriterion("finish_number <", value, "finishNumber");
            return (Criteria) this;
        }

        public Criteria andFinishNumberLessThanOrEqualTo(String value) {
            addCriterion("finish_number <=", value, "finishNumber");
            return (Criteria) this;
        }

        public Criteria andFinishNumberLike(String value) {
            addCriterion("finish_number like", value, "finishNumber");
            return (Criteria) this;
        }

        public Criteria andFinishNumberNotLike(String value) {
            addCriterion("finish_number not like", value, "finishNumber");
            return (Criteria) this;
        }

        public Criteria andFinishNumberIn(List<String> values) {
            addCriterion("finish_number in", values, "finishNumber");
            return (Criteria) this;
        }

        public Criteria andFinishNumberNotIn(List<String> values) {
            addCriterion("finish_number not in", values, "finishNumber");
            return (Criteria) this;
        }

        public Criteria andFinishNumberBetween(String value1, String value2) {
            addCriterion("finish_number between", value1, value2, "finishNumber");
            return (Criteria) this;
        }

        public Criteria andFinishNumberNotBetween(String value1, String value2) {
            addCriterion("finish_number not between", value1, value2, "finishNumber");
            return (Criteria) this;
        }
        
				
        public Criteria andDeptPhoneIsNull() {
            addCriterion("dept_phone is null");
            return (Criteria) this;
        }

        public Criteria andDeptPhoneIsNotNull() {
            addCriterion("dept_phone is not null");
            return (Criteria) this;
        }

        public Criteria andDeptPhoneEqualTo(String value) {
            addCriterion("dept_phone =", value, "deptPhone");
            return (Criteria) this;
        }

        public Criteria andDeptPhoneNotEqualTo(String value) {
            addCriterion("dept_phone <>", value, "deptPhone");
            return (Criteria) this;
        }

        public Criteria andDeptPhoneGreaterThan(String value) {
            addCriterion("dept_phone >", value, "deptPhone");
            return (Criteria) this;
        }

        public Criteria andDeptPhoneGreaterThanOrEqualTo(String value) {
            addCriterion("dept_phone >=", value, "deptPhone");
            return (Criteria) this;
        }

        public Criteria andDeptPhoneLessThan(String value) {
            addCriterion("dept_phone <", value, "deptPhone");
            return (Criteria) this;
        }

        public Criteria andDeptPhoneLessThanOrEqualTo(String value) {
            addCriterion("dept_phone <=", value, "deptPhone");
            return (Criteria) this;
        }

        public Criteria andDeptPhoneLike(String value) {
            addCriterion("dept_phone like", value, "deptPhone");
            return (Criteria) this;
        }

        public Criteria andDeptPhoneNotLike(String value) {
            addCriterion("dept_phone not like", value, "deptPhone");
            return (Criteria) this;
        }

        public Criteria andDeptPhoneIn(List<String> values) {
            addCriterion("dept_phone in", values, "deptPhone");
            return (Criteria) this;
        }

        public Criteria andDeptPhoneNotIn(List<String> values) {
            addCriterion("dept_phone not in", values, "deptPhone");
            return (Criteria) this;
        }

        public Criteria andDeptPhoneBetween(String value1, String value2) {
            addCriterion("dept_phone between", value1, value2, "deptPhone");
            return (Criteria) this;
        }

        public Criteria andDeptPhoneNotBetween(String value1, String value2) {
            addCriterion("dept_phone not between", value1, value2, "deptPhone");
            return (Criteria) this;
        }
        
			
		 public Criteria andLikeQuery(SysPosition record) {
		 	List<String> list= new ArrayList<String>();
		 	List<String> list2= new ArrayList<String>();
        	StringBuffer buffer=new StringBuffer();
			if(record.getId()!=null&&StrUtil.isNotEmpty(record.getId().toString())) {
    			 list.add("ifnull(id,'')");
    		}
			if(record.getDeptName()!=null&&StrUtil.isNotEmpty(record.getDeptName().toString())) {
    			 list.add("ifnull(dept_name,'')");
    		}
			if(record.getOrderNum()!=null&&StrUtil.isNotEmpty(record.getOrderNum().toString())) {
    			 list.add("ifnull(order_num,'')");
    		}
			if(record.getStatus()!=null&&StrUtil.isNotEmpty(record.getStatus().toString())) {
    			 list.add("ifnull(status,'')");
    		}
			if(record.getBankAccount()!=null&&StrUtil.isNotEmpty(record.getBankAccount().toString())) {
    			 list.add("ifnull(bank_account,'')");
    		}
			if(record.getDeptAddress()!=null&&StrUtil.isNotEmpty(record.getDeptAddress().toString())) {
    			 list.add("ifnull(dept_address,'')");
    		}
			if(record.getDeptZip()!=null&&StrUtil.isNotEmpty(record.getDeptZip().toString())) {
    			 list.add("ifnull(dept_zip,'')");
    		}
			if(record.getApplyNumber()!=null&&StrUtil.isNotEmpty(record.getApplyNumber().toString())) {
    			 list.add("ifnull(apply_number,'')");
    		}
			if(record.getFinishNumber()!=null&&StrUtil.isNotEmpty(record.getFinishNumber().toString())) {
    			 list.add("ifnull(finish_number,'')");
    		}
			if(record.getDeptPhone()!=null&&StrUtil.isNotEmpty(record.getDeptPhone().toString())) {
    			 list.add("ifnull(dept_phone,'')");
    		}
			if(record.getId()!=null&&StrUtil.isNotEmpty(record.getId().toString())) {
    			list2.add("'%"+record.getId()+"%'");
    		}
			if(record.getDeptName()!=null&&StrUtil.isNotEmpty(record.getDeptName().toString())) {
    			list2.add("'%"+record.getDeptName()+"%'");
    		}
			if(record.getOrderNum()!=null&&StrUtil.isNotEmpty(record.getOrderNum().toString())) {
    			list2.add("'%"+record.getOrderNum()+"%'");
    		}
			if(record.getStatus()!=null&&StrUtil.isNotEmpty(record.getStatus().toString())) {
    			list2.add("'%"+record.getStatus()+"%'");
    		}
			if(record.getBankAccount()!=null&&StrUtil.isNotEmpty(record.getBankAccount().toString())) {
    			list2.add("'%"+record.getBankAccount()+"%'");
    		}
			if(record.getDeptAddress()!=null&&StrUtil.isNotEmpty(record.getDeptAddress().toString())) {
    			list2.add("'%"+record.getDeptAddress()+"%'");
    		}
			if(record.getDeptZip()!=null&&StrUtil.isNotEmpty(record.getDeptZip().toString())) {
    			list2.add("'%"+record.getDeptZip()+"%'");
    		}
			if(record.getApplyNumber()!=null&&StrUtil.isNotEmpty(record.getApplyNumber().toString())) {
    			list2.add("'%"+record.getApplyNumber()+"%'");
    		}
			if(record.getFinishNumber()!=null&&StrUtil.isNotEmpty(record.getFinishNumber().toString())) {
    			list2.add("'%"+record.getFinishNumber()+"%'");
    		}
			if(record.getDeptPhone()!=null&&StrUtil.isNotEmpty(record.getDeptPhone().toString())) {
    			list2.add("'%"+record.getDeptPhone()+"%'");
    		}
        	buffer.append(" CONCAT(");
	        buffer.append(StrUtil.join(",",list));
        	buffer.append(")");
        	buffer.append(" like CONCAT(");
        	buffer.append(StrUtil.join(",",list2));
        	buffer.append(")");
        	if(!" CONCAT() like CONCAT()".equals(buffer.toString())) {
        		addCriterion(buffer.toString());
        	}
        	return (Criteria) this;
        }
        
        public Criteria andLikeQuery2(String searchText) {
		 	List<String> list= new ArrayList<String>();
        	StringBuffer buffer=new StringBuffer();
    		list.add("ifnull(id,'')");
    		list.add("ifnull(dept_name,'')");
    		list.add("ifnull(order_num,'')");
    		list.add("ifnull(status,'')");
    		list.add("ifnull(bank_account,'')");
    		list.add("ifnull(dept_address,'')");
    		list.add("ifnull(dept_zip,'')");
    		list.add("ifnull(apply_number,'')");
    		list.add("ifnull(finish_number,'')");
    		list.add("ifnull(dept_phone,'')");
        	buffer.append(" CONCAT(");
	        buffer.append(StrUtil.join(",",list));
        	buffer.append(")");
        	buffer.append("like '%");
        	buffer.append(searchText);
        	buffer.append("%'");
        	addCriterion(buffer.toString());
        	return (Criteria) this;
        }
        
}
	
    public static class Criteria extends GeneratedCriteria {
        protected Criteria() {
            super();
        }
    }

    public static class Criterion {
        private String condition;

        private Object value;

        private Object secondValue;

        private boolean noValue;

        private boolean singleValue;

        private boolean betweenValue;

        private boolean listValue;

        private String typeHandler;

        public String getCondition() {
            return condition;
        }

        public Object getValue() {
            return value;
        }

        public Object getSecondValue() {
            return secondValue;
        }

        public boolean isNoValue() {
            return noValue;
        }

        public boolean isSingleValue() {
            return singleValue;
        }

        public boolean isBetweenValue() {
            return betweenValue;
        }

        public boolean isListValue() {
            return listValue;
        }

        public String getTypeHandler() {
            return typeHandler;
        }

        protected Criterion(String condition) {
            super();
            this.condition = condition;
            this.typeHandler = null;
            this.noValue = true;
        }

        protected Criterion(String condition, Object value, String typeHandler) {
            super();
            this.condition = condition;
            this.value = value;
            this.typeHandler = typeHandler;
            if (value instanceof List<?>) {
                this.listValue = true;
            } else {
                this.singleValue = true;
            }
        }

        protected Criterion(String condition, Object value) {
            this(condition, value, null);
        }

        protected Criterion(String condition, Object value, Object secondValue, String typeHandler) {
            super();
            this.condition = condition;
            this.value = value;
            this.secondValue = secondValue;
            this.typeHandler = typeHandler;
            this.betweenValue = true;
        }

        protected Criterion(String condition, Object value, Object secondValue) {
            this(condition, value, secondValue, null);
        }
    }
}